<?php
//引导文件
require_once dirname( __FILE__ ) . '/../../Bootstrap.php';

//定义测试入口， 可以实现批量测试
if( !defined('PHPUnit_MAIN_METHOD') ) 
{
    define('PHPUnit_MAIN_METHOD', 'Api_AllTests::main');
}
//设定时区
date_default_timezone_set ( 'PRC' );
class Api_AllTests
{
    public static function main()
    {
        PHPUnit_TextUI_TestRunner::run( self::suite() );
    }

    public static function suite()
    {
        $suite = new PHPUnit_Framework_TestSuite('ProjectY - Api AllTests');
        $suite->addTestSuite( 'Api_UserControllerTest' );
        $suite->addTestSuite( 'Api_FeedControllerTest' );
        $suite->addTestSuite( 'Api_FriendControllerTest' );        
        return $suite;
    }
}

if( PHPUnit_MAIN_METHOD == 'Api_AllTests::main') 
{
    Api_AllTests::main();
}